export default defineNuxtRouteMiddleware((to, from) => {
    const token = useCookie('token')
  
    if (to.path.startsWith('/user') && !token.value) {
      return navigateTo('/sign-in')
    }
  })